FROM openjdk:8u342-jdk
MAINTAINER "zjtele"
ENV PROJECT_NAME="sxint-app" \
    BASE_DIR="/home/admin" \
    TIME_ZONE="Asia/Shanghai"
ARG PROJECT_PKG=target/$PROJECT_NAME.tar.gz

ADD ${PROJECT_PKG} $BASE_DIR
WORKDIR $BASE_DIR/$PROJECT_NAME
RUN apt update -y && apt install procps -y && ln -snf /usr/share/zoneinfo/$TIME_ZONE /etc/localtime && echo $TIME_ZONE > /etc/timezone
EXPOSE 8080
ENTRYPOINT ["bin/startup.sh","hup"]